const assert = require('assert')
const {faker} = require('@faker-js/faker')

describe('测试faker', () => {
    it('should 测试随机数', (done) => {
        faker.seed(1);

        const firstRandom = faker.number.int();

// Setting the seed again resets the sequence.
        faker.seed(2);

        const secondRandom = faker.number.int();

        console.log(firstRandom, secondRandom);

        assert.equal(firstRandom === secondRandom, false, '错误')
        done()

    });

    it('should 测试人名', () => {
        let i = 10
        while (i > 0) {
            i--;
            console.log(faker.hacker.noun());
            console.log(faker.image.url({width: 275, height: 150}));
            console.log(faker.database.collation());
        }

    });
});